// @flow
import React, { Component } from 'react'
import { Icon, Tooltip } from 'antd'
import moment from 'moment'

type Props = {
  data: Object
}

class JobWhereActions extends Component {
  props: Props
  render () {
    let value1 = this.props.data.jobId
    let text = '分析时间段:' + moment.utc(this.props.data.startTimeWhere, 'YYYY-MM-DDTHH:mm:ss.SSSZ').format('YYYY-MM-DD HH:mm:ss') + ' 到 ' + moment.utc(this.props.data.endTimeWhere, 'YYYY-MM-DDTHH:mm:ss.SSSZ').format('YYYY-MM-DD HH:mm:ss')
    return (
      <span>{value1}&nbsp;&nbsp;
        <Tooltip placement='top' title={text}>
          <Icon type='book' />
        </Tooltip>
      </span>
    )
  }
}

export default JobWhereActions
